You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Replaced Cinny's custom markdown parsing with marked which should drastically reduce the various random obscure errors and crashes caused by it.
Added math rendering support with KaTeX, sent using standard formatting of $ for inline and $$ for block with LaTeX.
Tbh I doubt I've tested this enough so there's probably still a bunch of bugs, especially in parsing html back to markdown, but hopefully it's less than our current system?
Might consider using another library like Turndown for converting html into markdown, currently using a partial custom parser with... well okay results.
Updated to also remove the WYSIWYG editor because it's largely unused, can be entirely covered by markdown, and complicates translating html to markdown. Keyboard shortcuts from the editor have been rewritten to instead apply markdown syntax.
Type of change
Bug fix (non-breaking change which fixes an issue)
New feature (non-breaking change which adds functionality)
Breaking change - removes the WYSIWYG editor.
This change requires a documentation update
Checklist:
My code follows the style guidelines of this project
I have performed a self-review of my own code
I have commented my code, particularly in hard-to-understand areas
I have made corresponding changes to the documentation
My changes generate no new warnings
AI disclosure:
Partially AI assisted (clarify which code was AI assisted and briefly explain what it does).
Fully AI generated (explain what all the generated code does in moderate detail).
Tests were AI generated and then reviewed by me. I can confirm that the tests probably test the right stuff.
I had AI do the initial merge and write the marked plugins for the link preview hiding and spoiler hiding features, which I then tested and reviewed.
I haven't looked at the code but where possible, please load libraries and such dynamically! So it's loaded when needed to reduce initial load and situations where people don't use a specific feature like math rendering.
the rendering side of the issue peprsists within this pr, could you introduce the message rendering part of this pr #726 (or actually the equivalent pr from cinny directly bcs it has more root changes that would hopefully be better since ajbura proposed the css solution even if it looks very overreaching 🤷🏻♀️) because this would would still be a persistent issue with people that use cinny and happen to for whatever reason send a message that ends in an empty list 🤷🏻♀️
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Replaced Cinny's custom markdown parsing with marked which should drastically reduce the various random obscure errors and crashes caused by it.
Added math rendering support with KaTeX, sent using standard formatting of $ for inline and $$ for block with LaTeX.
Supersedes #726
Fixes #711
Fixes #587
Fixes #467
Fixes #684
Tbh I doubt I've tested this enough so there's probably still a bunch of bugs, especially in parsing html back to markdown, but hopefully it's less than our current system?
Might consider using another library like Turndown for converting html into markdown, currently using a partial custom parser with... well okay results.
Updated to also remove the WYSIWYG editor because it's largely unused, can be entirely covered by markdown, and complicates translating html to markdown. Keyboard shortcuts from the editor have been rewritten to instead apply markdown syntax.
Type of change
Checklist:
AI disclosure:
Tests were AI generated and then reviewed by me. I can confirm that the tests probably test the right stuff.
I had AI do the initial merge and write the marked plugins for the link preview hiding and spoiler hiding features, which I then tested and reviewed.